This invention relates to video special effects, and more particularly to recursive video effects that provide a "trail" or "persistence" to a video image.
Recursive effects are commonly used in the video effects industry to leave a decaying after-image of an object as it moves within a field of video. Such an effect simulates a high persistence monitor, where the persistence is not provided by a high persistence phosphor but rather by a digital video effect.
It is conventional to process video signals in digital form in order to carry out special effects, particularly effects that involve delay or spatial transforms because of the ready availability of random access memories and other electronic components that operate on digital signals. Typically, the video signal is written into a frame memory and is subsequently read out, and the effect is accomplished by controlling the relationship between the read and write addresses.
Each pixel of a frame of a digital video signal has a unique logical address within the video raster. This logical address can be defined by the number of the line on which the pixel lies and the number of pixels between the beginning of the line and the pixel in question.
When a video signal is written into a frame memory, the pixel values are loaded into respective memory locations of the memory. The memory locations are defined by physical addresses that are not necessarily the same as the logical addresses within the raster. For instance, an image is considered to be two dimensional whereas a memory is a 1-dimensional array of memory locations that can be considered two dimensional by logical grouping. Such a grouping could map adjacent pixels of an image to widely separate memory locations with no effect on the observed visual output as long as the grouping method for reading tracks the method for writing.
FIG. 1 shows a prior art recursive effect circuit suitable for producing a decaying after-image or trail. The circuit shown in FIG. 1 receives a full-field background video signal and key control signal at terminal 2 and a shaped foreground video signal and the associated key control signal at terminal 4. The video signals are in digital form, such as NTSC D1, and the key control signals also are in digital form. Typically, the foreground video and key information represent a foreground object that does not occupy the entire video raster. The terminal 2 is connected to one input of a priority combiner 6 of the kind shown in U.S. Pat. No. 4,851,912, the disclosure of which is hereby incorporated by reference herein. The combiner 6 combines the background key and video data with a processed version of the foreground key and video data in accordance with the value of a priority signal P.sub.1, as described in U.S. Pat. No. 4,851,912. The terminal 4 is connected to the foreground input of a second priority combiner 12, which receives key and video data derived from a second source in a manner that will be described below. The combiner 12 combines the foreground key and video data with the key and video data provided by the second source in accordance with a priority signal P.sub.2. The output of combiner 12 constitutes the output of the recursive effect circuit and is the above-mentioned processed version of the foreground key and video data.
The output of combiner 12 is also loaded into a recursive memory 14, and the contents of recursive memory 14 are subsequently read out, providing a time-delayed version of the output of combiner 12. The recursive memory 14 is typically a frame memory, and consequently the delay imposed by the memory 14 is equal to one frame interval. A multiplier 16, which constitutes the second source of digital key and video data, multiplies the delayed key and video data from recursive memory 14 by a decay factor C.sub.d. Thus, the video signal applied to the second input of combiner 12 is an attenuated and delayed replica of the output of combiner 12. Consequently, the combiner mixes the frame that is currently being received at the terminal 4 with an attenuated replica of the previous frame that was output by the combiner 12. When an object represented by the foreground video signal moves relative to the video raster, the key and video data provided by the combiner 12 represent the foreground object of the current frame and a decaying after-image that forms a trail showing the path followed by the object to its current position. The output signal provided by the combiner 6 therefore represents the foreground object and its trail against the background represented by the background video data.
The decay factor C.sub.d determines the rate at which the after-image fades away. It can assume values between 0 and 1, with values near zero producing an almost instantaneous fade and values near one producing very long term persistence.
While there are several incidental variations on the basic approach described above, such as circuits that use a field store instead of a frame store, these variations are unimportant to the practice of the invention to be described below. For reference and background, however, the reader's attention is directed to U.S. Pat. No. 4,752,826 to Barnett, for "Intra-Field Recursive Interpolator", hereby incorporated by reference.
An apparatus for producing a recursive blur effect is described in U.S. Pat. No. 4,951,144 to the present inventor for "Recursive Video Blur Effect", hereby incorporated by reference. This recursive blur effect mixes neighboring decayed pixels in a way that produces an "airbrushed" trails effect. When recursive blurring is used for "flying" text characters, the trails left behind are smooth and the edges of the characters from previous frames are softened, and this creates a pleasing effect relative to the comparative harshness of the unblurred trails.
Another recursive apparatus is described in U.S. Pat. No. 5,153,711 issued Oct. 6, 1992 to the present inventor for "Recursive Video Hue Rotations to Obtain a Rainbow-Like Decaying After-Image", hereby incorporated by reference. In this apparatus a chrominance phase rotator is included within a recursive video effects loop, so that the hue of the after-image is altered as it decays. The chrominance phase rotator can be placed anywhere within the recursive loop, and can also be combined with a blurring effect and/or the decay factor multiplication needed for the basic recursive circuit.
The preceding discussion does not take account of latency, i.e. the number of clock delays from the output of the recursive memory back to the input of the recursive memory. These delays arise, for instance, from the decay multiplication in the multiplier 16 and the processing in the combiner 12. Therefore, if the pixel value from the physical address K is read from memory on read/write cycle q, the processed version of that pixel value does not become available at the input of the recursive memory until clock cycle q+L, where L is the latency, when the physical address K+L is accessed for reading. Therefore, in order to ensure that the processed pixel value will be written back to the same location, and preserve the relationship between logical addresses and physical addresses, the write address is offset by the latency L from the read address so that when the physical address K is accessed for reading, on read/write cycle q, the physical address that is accessed for writing is K-L.
The latency offset L may be considered as defining a vector having a horizontal component L.sub.h representing a number of pixels along a line of the video raster and a vertical component L.sub.v representing a number of lines of the raster. The offset due to latency is usually quite small (L.sub.v is zero and L.sub.h might be about plus 10), but L.sub.v may be positive if the recursive loop includes blurring. Neither L.sub.v nor L.sub.h can be negative.